//
//  ZDHomeViewController.m
//  砼车Demo
//
//  Created by apple on 15/12/30.
//  Copyright © 2015年 apple. All rights reserved.
//

#import "ZDHomeViewController.h"
#import "BMLoginController.h"
#import "ZDMenuView.h"

#import "BMAccountManager.h"
#import "BMRequest.h"
#import "BMAD.h"


@interface ZDHomeViewController ()

@property (nonatomic,strong) ZDMenuView *menuView;

@end

@implementation ZDHomeViewController



- (void)viewDidLoad {
    [super viewDidLoad];
    
    
    
    self.menuView = [[ZDMenuView alloc] initWithFrame:[UIScreen mainScreen].bounds];
    
}


- (void)getMenuAD
{
    BMRequest *request = [BMRequest requestWithPath:@"findAdList.htm" contentKey:@"adverList"];
    request.params = @{@"position":@2};
//    [BMAD ]
}


- (IBAction)searchCarAction:(UITapGestureRecognizer *)sender {
    
    
}

- (IBAction)showMenu:(UIBarButtonItem *)sender {
    

    if ([[BMAccountManager sharedInstance] isLogin]) {
        [_menuView show];
    }
    

   
//    [_menuView show]; //侧边栏 需要先判断是否登录

    
    BMLoginController *loginVC = [self.storyboard instantiateViewControllerWithIdentifier:@"loginVC"];
    [self presentViewController:loginVC animated:YES completion:nil];
    
}







@end
